#ifndef __usart_H
#define __usart_H
#ifdef __cplusplus
 extern "C" {
#endif

#include "gd32f4xx.h"
#include "main.h"

typedef enum
{
  HAL_OK       = 0x00U,
  HAL_ERROR    = 0x01U,
  HAL_BUSY     = 0x02U,
  HAL_TIMEOUT  = 0x03U
} HAL_StatusTypeDef;

#define UART_HandleTypeDef uint32_t


extern void _Error_Handler(char *, int);

void MX_USART1_UART_Init(void);
void MX_USART2_UART_Init(void);

void HAL_UART_RxCpltCallback(UART_HandleTypeDef huart);
void HAL_UART_TxCpltCallback(UART_HandleTypeDef huart);

#ifdef __cplusplus
}
#endif
#endif /*__ usart_H */
